import request from "../utils/request"

export const login=(data)=>{
  
  return request({
    method:"post",
    url:`https://api.java.crmeb.net/api/admin/login?account=demo&pwd=crmeb.com&key=${data.key}`,
    data:{
      data,
      account:data.account,pwd:data.pwd,
      key:data.key,
      code:data.code
    },
    headers:{
      "Content-Type": "application/json"
    }
  })
}

// 获取验证码
export const yzm=()=>{
  return request({
    method:"get",
    url:"https://api.java.crmeb.net/api/admin/validate/code/get"
  })
}

// 检验验证码
// /api/admin/validate/code/check
export const jiany=(data)=>{
  return request({
    method:"get",
    url:`https://api.java.crmeb.net/api/admin/validate/code/check`,
    data:{data}
    
  })
}

// 登录界面图片
// /api/admin/getLoginPic
export const getimg=()=>{
  return request({
    method:"get",
    url:`https://api.java.crmeb.net/api/admin/getLoginPic`,
    
    
  })
}